package com.weihe.android.webservice.v1_0;

import org.springframework.ws.server.endpoint.AbstractMarshallingPayloadEndpoint;

/**
 * Gets an order based of an Order ID
 * 
 * @author ylei
 */
public class GetOrderEndpoint extends AbstractMarshallingPayloadEndpoint {
    
    /**
     * A default constructor.
     */
    public GetOrderEndpoint() {
		super();
	}
    

    /**
     * @see org.springframework.ws.server.endpoint.AbstractMarshallingPayloadEndpoint#invokeInternal(java.lang.Object)
     */
    protected Object invokeInternal(Object serviceRequest) throws Exception {
        if (!(serviceRequest instanceof GetOrderRequest)) {
        		    throw new IllegalArgumentException("Service request object was not of the type " +
        		    "expected: GetOrderRequest");
        }

        //GetOrderRequest request = (GetOrderRequest) serviceRequest;        
        
        
        GetOrderResponse response = new GetOrderResponse();
        
        //response.setGetOrderResponse((OrderResponseWithServiceDetailType) converterService.convert(orderResponse, OrderResponseWithServiceDetailType.class));
        
        return response;
    }
	

}
